{extend name="public:layout" /}
{block name="content"}
<div class="page">
	<div class="fixed-bar">
		<div class="item-title">
		  <div class="subject">
		    <h3>管理员管理</h3>
		    <h5>网站后台管理员索引及管理</h5>
		  </div>
		</div>
	</div>
	<!-- 表格 -->
	<div class="table_list">
		<div class="mDiv"><div class="ftitle"><h3>管理员列表</h3><h5></h5></div></div>
		<div class="hDiv">
		    <table width="100%">
		    <thead>
		      <tr>
				<td width="150" align="center">操作</td>
				<td width="150" align="center">登录名</td>
				<td width="120" align="center">所属角色</td>
				<td width="120" align="center">最后登录IP</td>
				<td width="120" align="center">最后登录时间</td>
				<td width="120"  align="center">E-mail</td>
				<td width="120"  align="center">真实姓名</td>
		      </tr>
		    </thead>
		    </table>
		</div>

		<div class="tDiv">
		  <div class="tDiv2">
		    <div class="fbutton">
		        <div class="add"><span><i class="icon iconfont icon-guanliyuan"></i><a href="{:url('admin/manager/add')}">添加管理员</a></span></div>
		    </div>
		  </div>
		  <div style="clear:both"></div>
		</div>

		<div class="bDiv">
			<table width="100%">
			<tbody>
				{volist name="_list" id="vo"}
				<tr>
				  <td width="150" align="center"><a class="btn red" href="{:url('admin/manager/del',['id'=>$vo.userid])}" onclick="if(confirm('删除后将不能恢复，确认删除这  1 项吗？')){return true;} else {return false;}"><i class="icon iconfont icon-shanchu"></i>删除</a>
				  <a class="btn blue" href="{:url('admin/manager/edit',['id'=>$vo.userid])}"><i class="icon iconfont icon-edit"></i>编辑</a></td>
				  <td width="150" align="center">{$vo.username}</td>
				  <td width="120" align="center">{php} echo model('admin/AuthGroup')->getRoleIdName($vo['roleid']) {/php}</td>
				  <td width="120" align="center">{php} echo $vo['last_login_ip'] ? long2ip($vo['last_login_ip']) : '--' {/php}</td>
				  <td width="120" align="center">{php} echo $vo['last_login_time'] ? time_format($vo['last_login_time']) : '--' {/php}</td>
				  <td width="120" align="center">{$vo.email}</td>
				  <td width="120" align="center">{$vo.nickname}</td>
				</tr>
				{/volist}
			</tbody>
			</table>
		</div>
	</div>
</div>
{/block}